<?php /**
 * The template for displaying Category pages
 *
 * @link http://codex.wordpress.org/Template_Hierarchy
 *
 * @subpackage xique
 * @since xique 1.2
 */
get_header(); ?>
<?php get_search_form(); ?>
<div id="container"  class="alignleft" role="main">
	<?php if ( have_posts() ) : ?>
		<div>
			<!--<header>
				<h1 class="xique-main-header"><?php printf( __( '分类集合:', 'xique' ) . '&nbsp;%s', '<span>' . single_cat_title( '', false ) . '</span>' ); ?></h1>
			</header>-->
			<?php if ( category_description() ) : // Show an optional category description ?>
				<div class="archive-meta">
					<?php echo category_description(); ?>
				</div>
			<?php endif; ?>
		</div>
		<?php while( have_posts() ) : the_post(); 
			get_template_part( 'content', 'excerpt' );
			comments_template( '', true ); 
		endwhile;
		if ( $wp_query->max_num_pages > 1 ) : ?>
			<nav class="xique-single-navigation" role="navigation">
				<div class="xique-nav-previous wrap"><?php previous_posts_link( '&laquo;&nbsp;' . __( '上一页', 'xique' ) ); ?></div>
				<div class="xique-nav-next wrap"><?php next_posts_link( __( '下一页', 'xique' ) . '&nbsp;&raquo;' ); ?></div>
				<div class="clear"></div>
			</nav><!-- .xique-single-navigation -->
		<?php endif;
	else : ?>
		<div class="post">
			<h1 class="xique-main-header"><?php _e( '没有匹配的文章', 'xique' ); ?></h1>
			<div class="xique-posts round shadow" role="main">
				<header>
					<h2 class="wrap"><?php _e( '真对不起，什么都没找到！', 'xique' ); ?></h2>
				</header>
				<div class="entry">
					<div class="xique-text">
						<p><?php _e( '要不尝试搜索一下也许能找到你需要的文章。', 'xique' ); ?></p>
					</div>	
					<?php get_search_form(); ?>
				</div><!-- .entry-content -->
			</div> <!-- .xique-posts -->
		</div> <!-- .post -->
	<?php endif; ?>
</div> <!-- #container -->
<?php get_sidebar();
get_footer(); ?>
